/** 
 * Classe contenente i metodi per effettuare verifiche su numeri
 * @author Alessandro  Nasso
 * @version  1.0
 */


package beans;

//------------------------------------- import -------------------------------------------------------------

//----------------------------------------------------------------------------------------------------------


public class Number {


public boolean isNumber (String input)
{
  if (input.matches("((-|\\+)?[0-9]+(\\.[0-9]+)?)+")) {  
             return true;  
         } else {  
             return false;  
         }  
}


public boolean isInteger( String input )  
 {  
    try  
    {  
       Integer.parseInt( input );  
       return true;  
    }  
    catch( Exception e)  
    {  
       return false;  
    }  
 } 






}
